function move(ele, data, cb){
    clearInterval(ele.t);
    ele.t = setInterval(() => {
        var flag = true;
        for(var i in data){
            var now = i === "opacity" ? getStyle(ele, i) * 100 : parseInt(getStyle(ele, i));
            var speed = (data[i] - now)/10;
            speed = speed > 0 ? Math.ceil(speed) : Math.floor(speed);
            ele.style[i] = i === "opacity" ? (now + speed)/100 : now + speed + "px";
            if(now !== data[i]){
                flag = false;
            }
        }
        if(flag){
            clearInterval(ele.t);
            cb && cb();
        }
    }, 30);
}

function getStyle(ele, attr){
    if(ele.currentStyle){
        return ele.currentStyle[attr];
    }else{
        return getComputedStyle(ele,false)[attr];
    }
}
